package IO;

import java.io.*;

/**
 * 文件字符的输入
 */
public class IOtest05 {
    public static void main(String[] args) {
        File dest = new File("src/IO/dest.txt");

        Writer writer = null;

        try {
            writer = new FileWriter(dest);
            //方法一
            String msg = "dsdjsdnm就付款时间反馈";
            char[] datas = msg.toCharArray();
            writer.write(datas,0,datas.length);

            //方法二
            writer.write("dsdjsdnm就付款时间反馈");
            //方法三
            writer.append("dsdjsdnm").append("就付款时间反馈");
            writer.flush();
            writer.close();
        } catch(FileNotFoundException e){
            e.printStackTrace();
        }catch (IOException e) {
            e.printStackTrace();
        }
    }
}
